<?
include("session.php");
?>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script type="text/javascript" src="../webkit/utils/jquery.js"></script>
<link type="text/css" rel="stylesheet" href="page.css"/>
</head>
<body  bgcolor="#f4f4f4" style="margin:0px;" scroll=no>
<table width=100% cellspacing=1 cellpadding=3>
	<form name=f enctype='multipart/form-data' action="client_query.php?action=import" method=post target=free>
    <tr>
        <td align=right nowrap valign=middle>导入文件</td><td>
			<input name='upload_file' class='input' type=file style='width:400px'><br>
			(<font color=gray>列头说明：客户名称,地址,会员编号,联系电话1,联系电话2,有效期,客户类型</font>)<br>
			(<font color=gray>客户类型：1->单次,2->包年,3->VIP</font>)
		</td>
    </tr>
	</form>
	<tr>
		<td align=center colspan=4><hr size=1><input type="button" class="button" id="btn_save" value="确认导入" onclick="save()">　　<input type="button" class="button" value="关闭窗口" onclick="parent.closeDlg()"></td>
	</tr>
</table>
<script type="text/javascript">

	var f = document.f;
	function save() {
		if(f.upload_file.value == '') {
			alert('请选择要导入的文件！');
			return false;
		}
		if(confirm('确认要进行导入吗？')) {
			$('#btn_save').val('处理中...');
			$('#btn_save').attr('disabled', true);
			f.submit();
		}
	}; 


	function upload_completed(n) {
		alert("已成功导入记录["+n+"]条");
		parent.refreshGrid();
		parent.closeDlg();
	}
    
</script>
<iframe name="free" width=1 height=0></iframe>
</body>
</html>